package com.breakfast.fun.ui.user.help;

import android.widget.ListView;

import com.breakfast.fun.adapter.user.UserHelpCenterAdapter;
import com.breakfast.fun.base.BaseActivity;
import com.breakfast.fun.data.entity.user.help.Help;
import com.breakfast.fun.view.widget.TitleBarView;
import com.breakfast.fun.R;

import butterknife.Bind;

public class HelpCenterActivity extends BaseActivity<HelpCenterPresenter, HelpCenterModel> implements HelpCenterContract.View {

    @Bind(R.id.tbv_help_center)
    TitleBarView tbvHelpCenter;
    @Bind(R.id.lv_help_center)
    ListView lvHelpCenter;

    private UserHelpCenterAdapter adapter;

    @Override
    public int getLayoutId() {
        return R.layout.activity_help_center;
    }

    @Override
    public void initView() {
        tbvHelpCenter.setTitleNoRight("帮助中心");
        tbvHelpCenter.setBack(this);
    }

    @Override
    public void showHelp(Help help) {
        adapter = new UserHelpCenterAdapter(context, help.getData());
        lvHelpCenter.setAdapter(adapter);
    }


}
